package Views;

import UCM.*;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;

/**
 * a generic adaptor that converts a ucc into an action listener
 * @author Josh
 */
public class AdapterUCCToAL implements ActionListener {

    private UCController uc;

    /**
     * the constructor that initualises the uc
     * @param uc
     */
    public AdapterUCCToAL(UCController uc) {
        this.uc = uc;
    }
    // <editor-fold defaultstate="collapsed" desc=" UML Marker "> 
    // #[regen=yes,id=DCE.60B5C187-8D26-EC9C-57A1-958F729C480B]
    // </editor-fold> 

    /**
     * An action listener that calls the uc run function to start the logic
     * @param e
     */
    public void actionPerformed(ActionEvent e) {
        uc.run();
    }
}

